package inner_class;

class A {
    private int x = 5;
    class B {
        int getX() {
            return x;
        }
    }

    B getB() {
        return new B();
    }
}

public class Test1 {
    public static void main(String[] args) {
        A.B b = new A().getB();
        System.out.println(b.getX());

        A.B b1 = new A().new B();
        System.out.println(b1.getX());
    }
}
